package org.mipt.infsec.steganography.action;

import org.mipt.infsec.steganography.gui.GuiFrame;

import javax.swing.*;
import java.awt.event.ActionEvent;
import java.awt.event.InputEvent;
import java.awt.event.KeyEvent;

public class OpenAction extends AbstractProgramMenuAction {

	public OpenAction(GuiFrame owner) {
		super(owner, "Open...");
		putValue(ACCELERATOR_KEY, KeyStroke.getKeyStroke(KeyEvent.VK_O, InputEvent.CTRL_MASK));
	}

	@Override
	public void actionPerformed(ActionEvent evt) {
		owner.openImage();
	}

}